import random
# 生成随机测试数据的函数
def generate_random_data(length, min_val, max_val):
    return [random.randint(min_val, max_val) for _ in range(length)]